Skip to content

fix(multiple): resolve sass if function deprecation warnings#32674

Merged
crisbeto merged 1 commit intoangular:mainfrom
crisbeto:sass-fn-deprecation
Jan 20, 2026
Merged

fix(multiple): resolve sass if function deprecation warnings#32674
crisbeto merged 1 commit intoangular:mainfrom
crisbeto:sass-fn-deprecation

Conversation

@crisbeto
Copy link
Copy Markdown
Member

Sass has deprecated the if function in order to support the native CSS if(). These changes update all of our usages so users don't get deprecation warnings.

Note that I decided to replace it with @if/@else, instead of the new syntax, because the new syntax is:

  1. Harder to follow, in my opinion.
  2. Likely going to break users that aren't on the absolute latest version of Sass.

@crisbeto crisbeto added the target: patch This PR is targeted for the next patch release label Jan 19, 2026
@pullapprove pullapprove Bot requested a review from devversion January 19, 2026 11:44
[Sass has deprecated the `if` function](https://sass-lang.com/documentation/breaking-changes/if-function) in order to support the native CSS `if()`. These changes update all of our usages so users don't get deprecation warnings.

Note that I decided to replace it with `@if`/`@else`, instead of the new syntax, because the new syntax is:
1. Harder to follow, in my opinion.
2. Likely going to break users that aren't on the absolute latest version of Sass.
@crisbeto crisbeto force-pushed the sass-fn-deprecation branch from 5027dab to e0c8af2 Compare January 19, 2026 14:16
@crisbeto crisbeto added the action: merge The PR is ready for merge by the caretaker label Jan 19, 2026
@crisbeto crisbeto merged commit f3357c1 into angular:main Jan 20, 2026
34 of 35 checks passed
@crisbeto
Copy link
Copy Markdown
Member Author

This PR was merged into the repository. The changes were merged into the following branches:

crisbeto added a commit that referenced this pull request Jan 20, 2026
[Sass has deprecated the `if` function](https://sass-lang.com/documentation/breaking-changes/if-function) in order to support the native CSS `if()`. These changes update all of our usages so users don't get deprecation warnings.

Note that I decided to replace it with `@if`/`@else`, instead of the new syntax, because the new syntax is:
1. Harder to follow, in my opinion.
2. Likely going to break users that aren't on the absolute latest version of Sass.

(cherry picked from commit f3357c1)
@angular-automatic-lock-bot
Copy link
Copy Markdown

This issue has been automatically locked due to inactivity.
Please file a new issue if you are encountering a similar or related problem.

Read more about our automatic conversation locking policy.

This action has been performed automatically by a bot.

@angular-automatic-lock-bot angular-automatic-lock-bot Bot locked and limited conversation to collaborators Feb 20, 2026
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

action: merge The PR is ready for merge by the caretaker target: patch This PR is targeted for the next patch release

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants